<?php
/**
 * Created by PhpStorm.
 * User: ezy
 * Date: 2020-08-27
 * Time: 18:02
 */
namespace Reezy\OAuth\Hyperf;

use Reezy\OAuth\Contract\OAuthFactoryInterface;
use Reezy\OAuth\Contract\OAuthManagerInterface;
use Reezy\OAuth\OAuthFactory;
use Reezy\OAuth\OAuthManager;

class ConfigProvider
{

    public function __invoke(): array
    {
        return [
            'dependencies' => [
                 OAuthFactoryInterface::class => OAuthFactory::class,
                 OAuthManagerInterface::class => OAuthManager::class
            ],
            'publish' => [
                [
                    'id' => 'config',
                    'description' => 'description of this config file.', // 描述
                    'source' => __DIR__ . '/../publish/oauth.php',  // 对应的配置文件路径
                    'destination' => BASE_PATH . '/config/autoload/oauth.php', // 复制为这个路径下的该文件
                ],
            ],
        ];
    }
}